1. Field of the Invention
The invention relates to a distance measuring apparatus, and particularly to a distance measuring apparatus capable of dynamically adjusting a threshold value.
2. Description of the Related Art
In a light receiving system of a conventional rangefinder, a reflected light reflected from the target is converted into an electronic signal (i.e., a voltage or current signal). The electronic signal is then amplified by an amplifying circuit. Finally, a comparator determines whether the received signal is the reflected signal from the target or noise. Particularly, the comparator compares the amplified electronic signal with a reference signal with a predetermined reference value and generates a comparison result, and the comparison result determines whether the received signal is the reflected signal from the target or noise. Generally, the reference signal may be greater than the surrounding noise and less than the reflected signal from the target. Since the reflected signal is greater than the reference signal, the comparator outputs the comparison result with a high-level voltage. On the contrary, the comparator outputs the comparison result with a low-level voltage. When the comparator outputs the comparison result with a high-level voltage, the distance of the target is determined by calculating the time duration counted from a measuring light was emitted to the comparison result with a high-level voltage is outputted. However, the light receiving system of a conventional rangefinder may produce inaccurate results. FIG. 1 shows a signal waveform diagram of a conventional distance measuring apparatus, in which the horizontal and vertical axes are the measuring time and the intensity of the inputted signal, respectively. In FIG. 1, Vth represents the reference signal (for example a voltage), and curve S represents the input signal inputted into the comparator. The comparator outputs the comparison result with a high-level voltage once the input signal is greater than the reference signal, and the distance of the target is determined according to timing when the comparison result with a high-level voltage was outputted. Note that point A is the timing when the comparator outputs the comparison result with a high-level voltage. However, the correct timing should be point B. Thus, the distance result is inaccurate. Specifically, inaccuracies increase, when the target is made of a highly reflective material or the target is close to the distance measuring apparatus. In addition, when the target is made of a low reflective material or the target is far away from the distance measuring apparatus, the comparator does not output the comparison result with a high-level voltage since the input signal would be less than the reference signal; although the input signal is higher than noise. Thus, a distance measuring apparatus with accurate results not affected by material type of a target or distance is desired.